
import service from '../request';

const controller="procedureinfo"

/**
* 
* @param {*} data 
* @returns 
*/
function post(data:any):any {
    return service({
        method: 'post',
        url: controller,
        data: data,      
    })
}
/*
修改
*/
function put(Id:number,data:any) :any{
    return service({
        method: 'put',
        url: controller,
        data: data, 
        params:{Id}     
    })
}
/**
* 查找单个
* @param {*} data 
* @returns 
*/
function get(id:number) {
    return service({
        method: 'get',
        url: controller+"/"+id,
        // params: data,　　　　 
      
    }) 
}

/**
* 删除
* @param {*} data 
* @returns 
*/
function del(data:any):any {
    return service({
        method: 'delete',
        url: controller,
        params: data,　　　　 
      
    }) 
}
/**
 * 分页查询
 */
function Query(data:any):any{
    return service({
        method :'get',
        url:controller,
        params:data,
    })
}
/**
 * 获取全部
 */
function GetAll(data:any):any{
    return service({
        method :'POST',
        url:controller+'/getAll',
        params:data,
    })
}
/**
 * 获取全部
 */
function BusGet():any{
    return service({
        method :'GET',
        url:controller+'/BGet',
    })
}

function getByBusiness(business:Number):any{
    return service({
        method:'get',
        url:controller+'/getByBusiness',
        params:{business}
    })
}


export default{
    post,
    del,
    get,
    put,
    Query,
    GetAll,
    BusGet,
    getByBusiness
}